#include <stdio.h>
int main(){
	double num,grade,contgrade,max = 0,min = 100;
	printf("请输入学生成绩，以-1结束\n");
		for(num = 0;;num++){
			scanf("%*[^\n]");
			scanf("%*c");
			scanf("%lf",&grade);
	      if(grade == -1) break;
			contgrade = contgrade + grade;
			if(grade > max) max = grade;
			if(min > grade) min = grade;		
		}
	printf("总成绩为%lf \n",contgrade);
	printf("平均成绩为%lf \n",contgrade / num);
	printf("最高分%lf \n",max);
	printf("最低分%lf \n",min);
}
